home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Amiga Plus Special 24
/
AMIGAplus Sonderheft 24 (2000)(Falke)(DE)[!].iso
/
c
/
MPGui.doc
< prev
next >
Wrap
Text File
|
2000-01-01
|
19KB
|
643 lines
TABLE OF CONTENTS
MPGui.library/--background--
MPGui.library/--RunMPGui--
MPGui.library/AllocMPGuiHandleA
MPGui.library/FreeMPGuiHandle
MPGui.library/MPGuiCurrentAttrs
MPGui.library/MPGuiError
MPGui.library/MPGuiResponse
MPGui.library/MPGuiWindow
MPGui.library/ReadMPGui
MPGui.library/RefreshMPGui
MPGui.library/SetMPGuiGadgetValue
MPGui.library/SyncMPGuiRequest
MPGui.library/WriteMPGui
MPGui.library/--background-- MPGui.library/--background--
MPGui provides an easy way to display simple single colum requesters with
File/String/Number/Slider/Cycle/Check/ScreenMode/List gadgets.
It uses a text input file to specify the format of the Gui.
Menus can be provided.
Bottom gadgets can be "Ok/Cancel" for normal gadgets or "Save/Use/Cancel"
for preferences requesters.
From Version 5.2 the short cuts for these buttons will automatically be
disabled if required. The library is also localised.
From Version 5.4 opens locale.library(38) to work on OS3.0.
Normal Help and continuous Help is supported.
Keyboard shortcuts are supported.
The format of the file is:
* comment
Comment line
Any #n# (n>=0) will be replaced by parameters if supplied
## is changed to # if parameters are supplied
Some standard C conversions are done with \ values
\\ -> \
\" -> "
\t -> tab
\n -> newline
"command "HelpMessage
etc. Command (etc. is ignored)
"Comment" Comment for heading of requester
"HelpNode" Global Help Node for requester
GADGET "Title":"prefix"!HelpNode!HelpMessage!
A Gadget
GAGDET is type of gadget (see below).
"Title" is gadget title
"prefix" appears before the value in the result
if prefix includes %s then result
replaces %s instead
!HelpNode! is optional help string to
use in call back
!HelpMessage is displayed in text gadget at top
LFILE "Title":"prefix":"def"!Help!
Input file string and request gadget
Key activates
Right shift and key shows requester
SFILE "Title":"prefix":"def"!Help!
Output file string and gadget
Key activates
Right shift and key shows requester
FILE "T":"P":"def"!Help!
File string and request (input file)
Key activates
Right shift and key shows requester
OFILE "T":"P":"def":Y/N!Help!
Optional file (has checkbox)
Key toggles and activates if becomes selectable
Left shift and key activates if selectable
Right shift and key shows requester if selectable
ONUMBER "T":"P":"def":Y/N!Help!
Optional number (has checkbox)
Key toggles and activates if becomes selectable
Left shift and key activates if selectable
NUMBER "T":"P":"def"!Help!
Number
Key activates
CYCLE "Title"!Help!
Cycle gadget, each entry can be followed by other gadgets
Key cycles
Shift and key cycles back
"value1":"Prefix1"
"value2":"Prefix2"
gadgets
Only active when item is 2
"value3":"Prefix3"
ENDCYCLE:"number or valuen"
Finished by default value (numeric or string)
STRING "Title":"prefix":"def"!Help!
String - use for floating point as well
Key activates
OSTRING "Title":"prefix":"def":Y/N!Hlp!
String with checkbox
Key toggles and activates if becomes selectable
Left shift and key activates if selectable
CHECK "T":"P":"NPrefix":Y/N!Help
Check box gadget
NPrefix (optional) used if Check not selected
Key toggles
SLIDER "T":"P":"min":"max":"def"!Hlp!
Slider gadget
Key increases
Shift and key decreases
MODEn "T":"P":"def"!Help!
Screen Mode requester
Key shows requester
n == 1 -> Workbench modes
2 -> Workbench modes + NONE
3 -> All modes
4 -> All modes + NONE (3 and 4 do not work too well)
OMODEn "T":"P":"def":Y/N!Help!
Optional Screen Mode requester
Key toggles
Right shift and key shows requester if selectable
FONTn "T":"P":"def"!Help!
Font requester
Key shows requester
n == 1 -> All Fonts
2 -> Fixed width only
OFONTn "T":"P":"def":Y/N!Help!
Optional Font requester
Key toggles
Right shift and key shows requester if selectable
LIST "Title":!Help!
List view
Key cycles
Shift and key cycles back
"value1":"prefix1"
"value2":"prefix2"
ENDLIST:"number or valuen":"lines"
finished by default value and lines (optional) default 4
MLIST "Title":!Help!
List view
Key cycles
Left shift and key cycles back
Right shift and key toggles selected
"value1":"prefix1":"NPrefix1" (Negative Prefix optional)
"value2":"prefix2"
ENDMLIST:"values":"lines"
finished by default selected values (space seperated)
and lines (optional) default 4
BUTTON "Title" List of button gadgets - horizontal
If Title zero length then full width is used
"Button text1":"n"!Help!HelpMessage! n is number of button
"Button text2":"m"!Help!HelpMessage!
ENDBUTTON
TEXT "Title":"def"Y/N!Help!HelpMessage! (added in 5.1)
Text - If title 0 length then full width
Y to Center Text
MTEXT "def"Y/N!Help!HelpMessage! (added in 5.1)
Text without border
Y to Center Text
MPGui.library/--RunMPGui-- MPGui.library/--RunMPGui--
RunMPGui provides a simple Shell interface to MPGui.library
Parameters are:
FROM/A Input GUI file
TO/K Output file
RELMOUSE/S Open reqester by the pointer
PUBSCREEN/K Specify the public screen to open on
HELP/K AmigaGuide file to show help
CHELP/S Show help continuously
NEWLINE/S Put a new line between each gadget
PREFS/S Show Save/Use/Cancel gadgets rather than OK/Cancel
BUTTONS/K Command to run when a button is pressed
NOBUTTONS/S Do not show OK/Cancel gadgets
PARAMS/K/M Parameters to substitute in GUI file
The BUTTON command should be specified as "command %ld %ld"
The command is then passed two numbers - the address of the handle and
the number of the button.
Return a failure from this command to Cancel the GUI.
The response from MPGui is:
0 if OK is pressed;
5 if Cancel is pressed;
10 if there is an error in the GUI file;
20 if there is some fatal error.
Version 5 - Refreshes windows when a requester is open
Tries amigaguide.library version 34
Version 5.2 - Localised.
Version 5.3 - non beta
Version 5.4 - Opens locale.library(38) to work on OS3.0.
MPGui.library/AllocMPGuiHandleA MPGui.library/AllocMPGuiHandleA
NAME
AllocMPGuiHandleA -- Allocates an MPGuiHandle. (V3)
AllocMPGuiHandle -- Varargs version of AllocMPGuiHandleA (V3)
SYNOPSIS
gh = AllocMPGuiHandleA(taglist)
D0 A0
struct MPGuiHandle * AllocMPGuiHandleA(struct TagItem *);
gh = AllocMPGuiHandle(Tag1, ...)
struct MPGuiHandle * AllocMPGuiHandle(ULONG,...);
FUNCTION
Allocates an MPGuiHandle.
INPUTS
taglist - pointer to TagItem array.
Tags are:
MPG_PUBSCREENNAME - Data is char * name of public screen to use.